package com.lkd.http.controller;

import com.lkd.entity.TaskDetailsEntity;
import com.lkd.service.TaskDetailsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class TaskDetailController {

    @Autowired
    private TaskDetailsService detailsService;

    /**
     * 根据工单id查询补货详情
     * @param taskId
     * @return
     */
    @GetMapping("/taskDetails/{taskId}")
    public List<TaskDetailsEntity> getTaskDetailList(@PathVariable(name = "taskId")Long taskId){
        return detailsService.getTaskDetailList(taskId);
    }
}
